﻿using System;
using System.Diagnostics;
using System.Collections.Generic;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input.Touch;
using GauntletFramework.Input;
using System.Threading;
using GauntletFramework.StateManagment.Loading;

namespace GauntletFramework.Games.TestGame1
{
    public class Test1Load : StateLoading
    {
        public Test1Load()
        {
            Total = 100;
        }
        
        protected override void LoadingFunction()
        {
            while (Progress < Total)
            {
                Thread.Sleep(100);
                Progress++;
            }
        }
        public override void Draw(GameTime gameTime)
        {
            base.Draw(gameTime);
            
            SpriteBatch sb = StaticGame.SpriteBatch;
            
            sb.DrawString(LoadFont, Progress + " / " + Total, new Vector2(100,100), Color.White);
        }
    }
}
